User Registration
POST : http://<base_url>/digipay/v3/auth/user_register
This API is used to user registration
BODY PARAMS:-
Parameter | Type | Description | Value |
---|---|---|---|
dial_code | String | Country dial code. | +91 |
phone_number | String | hone number of the user. | 123456789 |
user_type | Int | Type of user (e.g., 1 for employee, 2 for customer).. | 2 |
first_name | String | First name of the user. | abc |
last_name | String | Last name of the user. | deo |
account_number_prefix | String | Prefix for account numbers. | ACCT |
password | String | User's password. | 123456 |
String | Email address of the user. | john.doe@example.com" | |
login_pin | String | PIN for login. | 11234 |
transaction_pin | String | PIN for transactions. | 1234 |
status_id | Int | Status identifier. | 1 |
birth_date | Long | Birth date in UNIX timestamp format. | 946684800000 |
image | String | URL to user's profile image. | https://example.com/profile/john.jpg |
kyc_status | Int | KYC status (e.g., 1 for pending, 2 for approved). | +91 |
country_id | String | Country identifier. | US |
kyc_process_status | Int | KYC process status (e.g., 1 for initiated, 2 for in progress, 3 for completed). | 1 |
location_poin | Int | KYC status (e.g., 1 for pending, 2 for approved). | +91 |
device_type | Int | Device ID. | 2 |
device_id | String | Unique identifier for the device | ABCDE12345 |
parent_user_id | String | Identifier of the parent user. | parent123" |
device_unique_id | String | Unique identifier for the device | UNIQUE123 |
referral_code | String | Referral code for the user. | REFCODE123 |
cretaed_by | String | Identifier of the user who created this record. | admin |
HEADERS:-
Parameter | Type | Description | Value |
---|---|---|---|
Authorization | String | It is a combination of type and token to authenticate user for the given token | Token duik7309njdlkhdauhknksadhjkas986876sd873j |
CompanyID | String | Company_id is a unique primary id, that is represent company detail | 76bc712200ca444fa334f9e55e5fd7a8 |
Request Body:-
Request Example
curl --request POST \
--url http://192.168.1.102:8014/digipay/v3/auth/user_register \
--header 'Authorization: Token eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiI2NWY0ZDI1MDliZmU0NTBmYTg4MTVhNTU5Njk3YmM0NyIsInJvbGVzIjpbIlJPTEVfQURNSU4iXSwiZXhwIjoxNjkzNTIxOTU1fQ.9oWwUzlFzmYB1ZOhaVamxKJH6DsMO8tFue2kbg2YyoI' \
--header 'CompanyID: 76bc712200ca444fa334f9e55e5fd7a8' \
--header 'accept: application/json' \
--header 'content-type: application/json' \
--data '
{
"dial_code": "+91",
"phone_number": "123456789",
"user_type": 2,
"first_name": "kgkjkl",
"account_number_prefix": "ACCT",
"last_name": "Doe",
"password": "123",
"email": "john.doe@example.com\"",
"login_pin": "1234",
"transaction_pin": "5678",
"status_id": 1,
"birth_date": 946684800000,
"image": "https://example.com/profile/john.jpg",
"kyc_status": 2,
"kyc_process_status": "3",
"location_point": "{ \"\"latitude\"\": 37.7749, \"\"longitude\"\": -122.4194 },",
"device_type": 2,
"device_id": "ABCDE12345",
"parent_user_id": "parent123\"",
"device_unique_id": "UNIQUE123",
"referral_code": "REFCODE123",
"cretaed_by": "admin"
}
'
Response:-
Response 200(OK)
{
"success": 1,
"error": [],
"data"" {
"message": "User registered successfully.",
"token": {
"type": "Token",
"token": "eyJhbGciOiJIUzUxMiJ9.eyJpYXQiOjE2NDc0OTEyMjR9.S_YjH-vZSvv495p5TkRsR3m10fGECdUHGlrXuNNSp-UUmiH-uIm4meYykEiy6BJzvEfjUkZXM3QAZAenQlB2IQ"
},
"user_id": "ebccea2ac4114b5aaa790221f72d3799"
}
}
Response 400(BAD REQUEST)
{
"success": 0,
"error"": [1],
"data": {
"message": "BAD_REQUEST",
}
}
RESPONSES :-
Status Code | Description |
---|---|
200 | OK |
400 | Bad Request |
404 | Not Found |
500 | Internal Server Error |